<nz-card>
  <div class="mb-md">
    <label> JOB名称:
      <input nz-input [(ngModel)]="this.searchBeans[0].attributeValue" name="username" style="width: 150px;"
             class="mr-sm"/>
    </label>
    <label> 所属组:
      <input nz-input [(ngModel)]="this.searchBeans[1].attributeValue" name="username" style="width: 150px;"
             class="mr-sm"/>
    </label>

    <button nz-button (click)="this.loadListData()" [nzType]="'primary'">搜索</button>
    <button nz-button (click)="this.clearParam(); this.loadListData()">重置</button>
  </div>

  <nz-divider [nzDashed]=true style="padding: 0;margin: 0;" ></nz-divider>

  <div style="padding: 10px;">
    <button nz-button (click)="openEdit()" [nzType]="'primary'">新增</button>
  </div>

  <nz-table #basicTable [nzData]="deviceGroups" [nzLoading]="loading" nzBordered nzSize="small">
    <thead>
    <tr>
      <th>JOB名称</th>
      <th>所属组</th>
      <th>CORN表达式</th>
      <th>描述信息</th>
      <th>状态</th>
      <th>下次执行时间</th>
      <th>操作区</th>
    </tr>
    </thead>
    <tbody>
    <tr *ngFor="let data of basicTable.data">
      <td>{{data.jobName}}</td>
      <td>{{data.jobGroupName}}</td>
      <td>{{data.corn}}</td>
      <td>{{data.description}}</td>
      <td>{{data.jobStatus}}</td>
      <td>{{data.nextFireTime}}</td>
      <td>
        <a nz-button nzType="link" (click)="openEdit(data)"><i nz-icon nzType="edit"></i>编辑</a>
        <a nz-button nzType="link" (click)="delete(data.jobName,data.jobGroupName)">
          <i nz-icon nzType="delete"></i>删除</a>
      </td>
    </tr>
    </tbody>
  </nz-table>
</nz-card>

<app-task-edit #deviceEditComponent (voted)="onSmt()"></app-task-edit>
